package com.sangu.enums;

public enum AppCodeEnum {

    OK(200,"处理完成"),
    SUCCESS(200,"操作成功"),
    NEED_LOGIN(401,"需要登录"),
    NO_AUTH(402,"没有权限"),
    SYSTEM_ERROR(500,"系统错误"),
    USERNAME_EXIST(501,"用户名已存在"),
    PHONE_EXIST(502,"手机号已存在"),
    EMAIL_EXIST(503,"邮箱号已存在"),
    USERNAME_NOTNULL(504,"用户名不能为空"),
    LOGIN_ERROR(505,"登录失败");

    int code;
    String msg;

    AppCodeEnum(int code,String msg){
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
